<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <h3></h3>
    <script>
        function object(name, age, ahao) {
            this.name = name;
            this.age = age;
            this.ahao = ahao;
            this.sing = function (song) {
                console.log('大招:' + song);
            }
        }
        var cyj = new object("程咬金", 183, "找虐");
        var tias = console.log(cyj.name + "\n" + cyj.age + "\n" + cyj.ahao);
        var tims = cyj.sing("自动回复")
        var titas = document.querySelector('h3')
        titas.innerHTML("<h1>" + cyj.name + cyj.age + cyj.ahao + "<h1/>");
    </script>
</body>

</html>